package org.sucri.dao;

import org.directwebremoting.annotations.DataTransferObject;
import org.directwebremoting.annotations.RemoteProperty;

import javax.persistence.*;
import java.sql.Date;

/**
 * Created by IntelliJ IDEA.
 * User: Wen Yu
 * Date: Aug 30, 2007
 * Time: 11:26:57 PM
 * To change this template use File | Settings | File Templates.
 */
@DataTransferObject
@Entity
@Table(catalog = "vpp", name = "USERS")
public class UsersEntity
{
  private int id;
  private String uname;
  private String password;
  private String email;
  private int credits;
  private String lookup;
  private int petsallowed;
  private String lastseen;
  private String firstname;
  private String lastname;
  private Date dateofbirth;

  @RemoteProperty
  @Basic
  @Column(name = "dateofbirth", length = 0)
  public Date getDateofbirth()
  {
    return dateofbirth;
  }

  @RemoteProperty
  public void setDateofbirth(Date dateofbirth)
  {
    this.dateofbirth = dateofbirth;
  }

  @RemoteProperty
  @Basic
  @Column(name = "lastname", nullable = false, length = 45)
  public String getLastname()
  {
    return lastname;
  }

  @RemoteProperty
  public void setLastname(String lastname)
  {
    this.lastname = lastname;
  }

  @RemoteProperty
  @Basic
  @Column(name = "firstname", nullable = false, length = 45)
  public String getFirstname()
  {
    return firstname;
  }

  @RemoteProperty
  public void setFirstname(String firstname)
  {
    this.firstname = firstname;
  }

  @RemoteProperty
  @Basic
  @Column(name = "lastseen", nullable = false, length = 30)
  public String getLastseen()
  {
    return lastseen;
  }

  @RemoteProperty
  public void setLastseen(String lastseen)
  {
    this.lastseen = lastseen;
  }

  @RemoteProperty
  @Basic
  @Column(name = "petsallowed", length = 10)
  public int getPetsallowed()
  {
    return petsallowed;
  }

  @RemoteProperty
  public void setPetsallowed(int petsallowed)
  {
    this.petsallowed = petsallowed;
  }

  @RemoteProperty
  @Basic
  @Column(name = "lookup", nullable = false, length = 225)
  public String getLookup()
  {
    return lookup;
  }

  @RemoteProperty
  public void setLookup(String lookup)
  {
    this.lookup = lookup;
  }

  @RemoteProperty
  @Basic
  @Column(name = "credits", nullable = false, length = 10)
  public int getCredits()
  {
    return credits;
  }

  @RemoteProperty
  public void setCredits(int credits)
  {
    this.credits = credits;
  }

  @RemoteProperty
  @Basic
  @Column(name = "email", nullable = false, length = 50)
  public String getEmail()
  {
    return email;
  }

  @RemoteProperty
  public void setEmail(String email)
  {
    this.email = email;
  }

  @RemoteProperty
  @Basic
  @Column(name = "password", nullable = false, length = 15)
  public String getPassword()
  {
    return password;
  }

  @RemoteProperty
  public void setPassword(String password)
  {
    this.password = password;
  }

  @RemoteProperty
  @Basic
  @Column(name = "uname", nullable = false, length = 15)
  public String getUname()
  {
    return uname;
  }

  @RemoteProperty
  public void setUname(String uname)
  {
    this.uname = uname;
  }

  @RemoteProperty
  @Id
  @Column(name = "id", nullable = false, length = 10)
  public int getId()
  {
    return id;
  }

  public void setId(int id)
  {
    this.id = id;
  }
}
